const path = require('path')

module.exports = app => {
  // 加载所有的自定义校验规则
  const directory = path.join(app.config.baseDir, 'app/validate')
  app.loader.loadToApp(directory, 'validate')
}